﻿using System; 
using System.Collections.Generic;
using System.ComponentModel;
using System.ComponentModel.DataAnnotations;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using CellphoneRepair.DAL;

namespace CellphoneRepair.Entities
{
    public class Kehu
    {
        [Key]
        [DisplayName("客户ID")]
        public string Idkehu { get; set; }

        [DisplayName("姓名")]
        [Required(ErrorMessage = "请填写姓名")]
        public string Xingming { get; set; }

        [DisplayName("电话号码")]
        [Required(ErrorMessage = "请填写电话号码")]
        public string Phoneno { get; set; }

        [DisplayName("QQ号码")]
        public string Qq { get; set; }

    }

    public class KehuBll:DBCommon<Kehu>
    {
        public override string TableName
        {
            get { return "kehu"; }
        }

        public override string PrimaryKey
        {
            get { return "idkehu"; }
        }

        public override string ConnKey
        {
            get { return "default"; }
        }

        public override string ParaF
        {
            get { return "@"; }
        }
    }
}
